#!/bin/bash
docker stop openwrt 
docker rm openwrt 
docker network disconnect -f macnet
docker network rm macnet
mkdir /root/op 
cp ./* /root/op/ 
docker network create -d macvlan --subnet=192.168.2.0/24 --gateway=192.168.2.1 -o parent=eth0 macnet 
docker run --restart always -d --network macnet --name openwrt --privileged -v /root/op:/share_data unifreq/openwrt-aarch64 /sbin/init
docker exec -it  openwrt bash /share_data/set_network.sh
